Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added new nearestPointOnLine default and custom distance unit #1058

Merged

Conversation

langsmith
Copy link

This pr resolves #1054 by adjusting TurfMisc.nearestPointOnLine() to use TurfConstants.UNIT_KILOMETERS by default. This pr also exposes a version of TurfMisc.nearestPointOnLine() which takes in a @TurfConstants.TurfUnitCriteria String so that a developer can pass in a preferred distance unit.

cc @gwimmel , who requested this.

@langsmith langsmith added the Turf label Jun 25, 2019
@langsmith langsmith requested a review from tobrun June 25, 2019 15:12
@langsmith langsmith self-assigned this Jun 25, 2019
@langsmith langsmith merged commit faa62bf into master Jun 25, 2019
@langsmith langsmith deleted the ls-adding-kilometers-default-to-nearestPointOnLine branch June 25, 2019 15:42
@langsmith langsmith added this to the v4.9.0 milestone Sep 18, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

TurfMisc.nearestPointOnLine() should use kilometers as default unit for dist
2 participants